/**************************************************************************//**
 * \file      ConfigPanel.cpp
 * \author    Gary Harris
 * \date      01-02-2010
 *
 * DoxyBlocks - doxygen integration for Code::Blocks. \n
 * Copyright (C) 2010 Gary Harris.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 *****************************************************************************/
#include "ConfigPanel.h"
#include <sdk.h> // Code::Blocks SDK

//(*InternalHeaders(ConfigPanel)
#include <wx/intl.h>
#include <wx/string.h>
//*)
#include <wx/filedlg.h>
#include <wx/fontutil.h>

#include <configmanager.h>
#include <editorcolourset.h>
#include <editormanager.h>
#include <tinyxml.h>

#include "version.h"


//(*IdInit(ConfigPanel)
const long ConfigPanel::ID_RADIOBOX_BLOCKCOMMENTS = wxNewId();
const long ConfigPanel::ID_TEXTCTRL_BLOCKCOMMENT = wxNewId();
const long ConfigPanel::ID_RADIOBOX_LINECOMMENTS = wxNewId();
const long ConfigPanel::ID_TEXTCTRL_LINECOMMENT = wxNewId();
const long ConfigPanel::ID_PANEL2 = wxNewId();
const long ConfigPanel::ID_TEXTCTRL_PROJECTNUMBER = wxNewId();
const long ConfigPanel::ID_CHECKBOX_USEAUTOVERSION = wxNewId();
const long ConfigPanel::ID_TEXTCTRLOUTPUT_DIRECTORY = wxNewId();
const long ConfigPanel::ID_STATICTEXT5 = wxNewId();
const long ConfigPanel::ID_CHOICE_OUTPUT_LANGUAGE = wxNewId();
const long ConfigPanel::ID_CHECKBOX_EXTRACT_ALL = wxNewId();
const long ConfigPanel::ID_CHECKBOX_EXTRACTPRIVATE = wxNewId();
const long ConfigPanel::ID_CHECKBOX_EXTRACTSTATIC = wxNewId();
const long ConfigPanel::ID_CHECKBOX_WARNINGS = wxNewId();
const long ConfigPanel::ID_CHECKBOX_WARN_IF_DOC_ERROR = wxNewId();
const long ConfigPanel::ID_CHECKBOX_WARN_IF_UNDOCUMENTED = wxNewId();
const long ConfigPanel::ID_CHECKBOX_WARN_NO_PARAMDOC = wxNewId();
const long ConfigPanel::ID_CHECKBOX_ALPHABETICAL_INDEX = wxNewId();
const long ConfigPanel::ID_PANEL3 = wxNewId();
const long ConfigPanel::ID_CHECKBOX_GENERATE_HTML = wxNewId();
const long ConfigPanel::ID_CHECKBOX_GENERATE_HTMLHELP = wxNewId();
const long ConfigPanel::ID_CHECKBOX_GENERATE_CHI = wxNewId();
const long ConfigPanel::ID_CHECKBOX_BINARY_TOC = wxNewId();
const long ConfigPanel::ID_CHECKBOX_GENERATE_LATEX = wxNewId();
const long ConfigPanel::ID_CHECKBOX_GENERATE_RTF = wxNewId();
const long ConfigPanel::ID_CHECKBOX_GENERATE_MAN = wxNewId();
const long ConfigPanel::ID_CHECKBOX_GENERATE_XML = wxNewId();
const long ConfigPanel::ID_CHECKBOX_GENERATE_AUTOGEN_DEF = wxNewId();
const long ConfigPanel::ID_CHECKBOX_GENERATE_PERLMOD = wxNewId();
const long ConfigPanel::ID_CHECKBOX_ENABLE_PREPROCESSING = wxNewId();
const long ConfigPanel::ID_CHECKBOX_CLASS_DIAGRAMS = wxNewId();
const long ConfigPanel::ID_CHECKBOX_HAVE_DOT = wxNewId();
const long ConfigPanel::ID_PANEL4 = wxNewId();
const long ConfigPanel::ID_STATICTEXT2 = wxNewId();
const long ConfigPanel::ID_TEXTCTRL_PATHDOXYGEN = wxNewId();
const long ConfigPanel::ID_BUTTON_BROWSEDOXYGEN = wxNewId();
const long ConfigPanel::ID_STATICTEXT4 = wxNewId();
const long ConfigPanel::ID_TEXTCTRL_PATHDOXYWIZARD = wxNewId();
const long ConfigPanel::ID_BUTTON_BROWSEDOXYWIZARD = wxNewId();
const long ConfigPanel::ID_STATICTEXT3 = wxNewId();
const long ConfigPanel::ID_TEXTCTRL_PATHHHC = wxNewId();
const long ConfigPanel::ID_BUTTON_BROWSEHHC = wxNewId();
const long ConfigPanel::ID_STATICTEXT6 = wxNewId();
const long ConfigPanel::ID_TEXTCTRL_PATHDOT = wxNewId();
const long ConfigPanel::ID_BUTTON_BROWSEDOT = wxNewId();
const long ConfigPanel::ID_STATICTEXT7 = wxNewId();
const long ConfigPanel::ID_TEXTCTRL_PATHCHMVIEWER = wxNewId();
const long ConfigPanel::ID_BUTTON_BROWSECHMVIEWER = wxNewId();
const long ConfigPanel::ID_CHECKBOX_OVERWRITEDOXYFILE = wxNewId();
const long ConfigPanel::ID_CHECKBOX_PROMPTB4OVERWRITING = wxNewId();
const long ConfigPanel::ID_CHECKBOX_USEATINTAGS = wxNewId();
const long ConfigPanel::ID_CHECKBOX_LOADTEMPLATE = wxNewId();
const long ConfigPanel::ID_CHECKBOX_USEINTERNALVIEWER = wxNewId();
const long ConfigPanel::ID_CHECKBOX_RUNHTML = wxNewId();
const long ConfigPanel::ID_CHECKBOX_RUNCHM = wxNewId();
const long ConfigPanel::ID_PANEL1 = wxNewId();
const long ConfigPanel::ID_NOTEBOOK_PREFS = wxNewId();
//*)

BEGIN_EVENT_TABLE(ConfigPanel,wxPanel)
    //(*EventTable(ConfigPanel)
    //*)
END_EVENT_TABLE()

/*
 * 实现功能: Constructor.
 * 实现功能:构造函数
 */
ConfigPanel::ConfigPanel(wxWindow* parent, DoxyBlocks *pOwner, wxWindowID /*id*/,const wxPoint& /*pos*/,const wxSize& /*size*/) :
    m_pOwnerClass(pOwner)
{
    // ********************************************************************************************
    // I don't use XRC for this plug-in because cbStyledTextCtrl isn't handled properly.
    // This method still requires some adjustments. See below.
    // 我没有为这个插件使用XRC,因为cbStyledTextCtrl没有得到正确的处理.
    // 这种方法仍然需要一些调整.见下文.
    // ********************************************************************************************
    //(*Initialize(ConfigPanel)
    // 初始化配置面板
    wxBoxSizer* BoxSizer10;
    wxBoxSizer* BoxSizer11;
    wxBoxSizer* BoxSizer12;
    wxBoxSizer* BoxSizer13;
    wxBoxSizer* BoxSizer14;
    wxBoxSizer* BoxSizer15;
    wxBoxSizer* BoxSizer16;
    wxBoxSizer* BoxSizer17;
    wxBoxSizer* BoxSizer18;
    wxBoxSizer* BoxSizer19;
    wxBoxSizer* BoxSizer1;
    wxBoxSizer* BoxSizer20;
    wxBoxSizer* BoxSizer21;
    wxBoxSizer* BoxSizer22;
    wxBoxSizer* BoxSizer2;
    wxBoxSizer* BoxSizer3;
    wxBoxSizer* BoxSizer4;
    wxBoxSizer* BoxSizer5;
    wxBoxSizer* BoxSizer6;
    wxBoxSizer* BoxSizer7;
    wxBoxSizer* BoxSizer8;
    wxBoxSizer* BoxSizer9;
    wxNotebook* NotebookPrefs;
    wxPanel* Panel1;
    wxPanel* Panel2;
    wxPanel* Panel3;
    wxPanel* Panel4;
    wxStaticBoxSizer* StaticBoxSizer10;
    wxStaticBoxSizer* StaticBoxSizer11;
    wxStaticBoxSizer* StaticBoxSizer12;
    wxStaticBoxSizer* StaticBoxSizer1;
    wxStaticBoxSizer* StaticBoxSizer2;
    wxStaticBoxSizer* StaticBoxSizer3;
    wxStaticBoxSizer* StaticBoxSizer4;
    wxStaticBoxSizer* StaticBoxSizer5;
    wxStaticBoxSizer* StaticBoxSizer6;
    wxStaticBoxSizer* StaticBoxSizer7;
    wxStaticBoxSizer* StaticBoxSizer8;
    wxStaticBoxSizer* StaticBoxSizer9;
    wxStaticText* StaticText1;
    wxStaticText* StaticText2;
    wxStaticText* StaticText3;
    wxStaticText* StaticText4;
    wxStaticText* StaticText5;
    wxStaticText* StaticText6;
    wxStaticText* StaticText7;
    wxStaticText* StaticText8;

    Create(parent, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL, _T("wxID_ANY"));
    BoxSizer1 = new wxBoxSizer(wxVERTICAL);
    NotebookPrefs = new wxNotebook(this, ID_NOTEBOOK_PREFS, wxDefaultPosition, wxDefaultSize, 0, _T("ID_NOTEBOOK_PREFS"));
    Panel2 = new wxPanel(NotebookPrefs, ID_PANEL2, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL, _T("ID_PANEL2"));
    BoxSizer6 = new wxBoxSizer(wxVERTICAL);
    BoxSizer2 = new wxBoxSizer(wxHORIZONTAL);
    wxString __wxRadioBoxChoices_1[6] =
    {
    	wxT("C/JavaDoc"),
        wxT("C++ Exclamation"),
        wxT("C++ Slash"),
        wxT("Qt"),
        wxT("Visible C Style"),
        wxT("Visible C++ Style")
    };
    RadioBoxBlockComments = new wxRadioBox(Panel2, ID_RADIOBOX_BLOCKCOMMENTS, wxT("块注释风格"), wxDefaultPosition, wxDefaultSize, 6, __wxRadioBoxChoices_1, 1, wxRA_SPECIFY_COLS, wxDefaultValidator, _T("ID_RADIOBOX_BLOCKCOMMENTS"));
    RadioBoxBlockComments->SetToolTip(wxT("选择首选的块注释样式."));
    BoxSizer2->Add(RadioBoxBlockComments, 1, wxALL|wxEXPAND, 5);
    StaticBoxSizer1 = new wxStaticBoxSizer(wxVERTICAL, Panel2, wxT("块注释示例"));
    TextCtrlBlockComment = new cbStyledTextCtrl(Panel2, ID_TEXTCTRL_BLOCKCOMMENT, wxDefaultPosition, wxSize(150,150));
    TextCtrlBlockComment->SetToolTip(wxT("使用所选块注释样式的示例代码."));
    // wxSmith doesn't handle cbStyledTextCtrl initialisation properly. Replace the line above with the commented one below.
    // You will need to do this every time wxSmith rewrites this entry.
    // TextCtrlBlockComment = new cbStyledTextCtrl(Panel2, ID_TEXTCTRL_BLOCKCOMMENT, wxDefaultPosition, wxSize(150,150));
    // 史密斯(wxSmith)无法正确处理cbStyledTextCtrl初始化.用下面注释的行替换上面的行.
    // 每次wxSmith重写这个条目时都需要这样做.
    StaticBoxSizer1->Add(TextCtrlBlockComment, 1, wxALL|wxEXPAND, 5);
    BoxSizer2->Add(StaticBoxSizer1, 3, wxALL|wxEXPAND, 5);
    BoxSizer6->Add(BoxSizer2, 1, wxALL|wxEXPAND, 5);
    BoxSizer10 = new wxBoxSizer(wxHORIZONTAL);
    wxString __wxRadioBoxChoices_2[4] =
    {
    	wxT("C/JavaDoc"),
        wxT("C++ Exclamation"),
        wxT("C++ Slash"),
        wxT("Qt")
    };
    RadioBoxLineComments = new wxRadioBox(Panel2, ID_RADIOBOX_LINECOMMENTS, wxT("行注释风格"), wxDefaultPosition, wxDefaultSize, 4, __wxRadioBoxChoices_2, 1, wxRA_SPECIFY_COLS, wxDefaultValidator, _T("ID_RADIOBOX_LINECOMMENTS"));
    RadioBoxLineComments->SetToolTip(wxT("选择首选的行注释样式."));
    BoxSizer10->Add(RadioBoxLineComments, 1, wxALL|wxEXPAND, 5);
    StaticBoxSizer3 = new wxStaticBoxSizer(wxVERTICAL, Panel2, wxT("行注释示例"));
    TextCtrlLineComment = new cbStyledTextCtrl(Panel2, ID_TEXTCTRL_LINECOMMENT, wxDefaultPosition, wxSize(150,150));
    TextCtrlLineComment->SetToolTip(wxT("使用所选行注释样式的示例代码."));
    // wxSmith doesn't handle cbStyledTextCtrl initialisation properly. Replace the line above with the commented one below.
    // You will need to do this every time wxSmith rewrites this entry.
    // TextCtrlLineComment = new cbStyledTextCtrl(Panel2, ID_TEXTCTRL_LINECOMMENT, wxDefaultPosition, wxSize(150,150));
    StaticBoxSizer3->Add(TextCtrlLineComment, 1, wxALL|wxEXPAND, 5);
    BoxSizer10->Add(StaticBoxSizer3, 3, wxALL|wxEXPAND, 5);
    BoxSizer6->Add(BoxSizer10, 1, wxALL|wxEXPAND, 5);
    Panel2->SetSizer(BoxSizer6);
    BoxSizer6->Fit(Panel2);
    BoxSizer6->SetSizeHints(Panel2);
    Panel3 = new wxPanel(NotebookPrefs, ID_PANEL3, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL, _T("ID_PANEL3"));
    BoxSizer4 = new wxBoxSizer(wxVERTICAL);
    StaticBoxSizer2 = new wxStaticBoxSizer(wxVERTICAL, Panel3, wxT("项目"));
    BoxSizer5 = new wxBoxSizer(wxHORIZONTAL);
    StaticText1 = new wxStaticText(Panel3, wxID_ANY, wxT("项目号"), wxDefaultPosition, wxDefaultSize, 0, _T("wxID_ANY"));
    BoxSizer5->Add(StaticText1, 0, wxTOP|wxBOTTOM|wxLEFT|wxALIGN_CENTER_VERTICAL, 5);
    TextCtrlProjectNumber = new wxTextCtrl(Panel3, ID_TEXTCTRL_PROJECTNUMBER, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_TEXTCTRL_PROJECTNUMBER"));
    //TextCtrlProjectNumber->SetToolTip(wxT("The PROJECT_NUMBER tag can be used to enter a project or revision number.\nThis could be handy for archiving the generated documentation or\nif some version control system is used."));
    TextCtrlProjectNumber->SetToolTip(wxT("项目编号标记可用于输入项目或修订号.\n这对于存档生成的文档或使用某个版本控制系统可能很方便."));

    BoxSizer5->Add(TextCtrlProjectNumber, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    CheckBoxUseAutoVersion = new wxCheckBox(Panel3, ID_CHECKBOX_USEAUTOVERSION, wxT("使用自动版本"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_USEAUTOVERSION"));
    CheckBoxUseAutoVersion->SetValue(false);
    CheckBoxUseAutoVersion->Disable();
    //CheckBoxUseAutoVersion->SetToolTip(wxT("Use the version number provided by the Autoversion plug-in.\nIf this option is selected, DoxyBlocks will extract the version number\nfrom the Autoversion header file.\nThe format used is MAJOR.MINOR.BUILD.\nThis option is disabled if Autoversioning is not enabled for the project."));
    CheckBoxUseAutoVersion->SetToolTip(wxT("使用自动版本插件提供的版本号.\n如果选择此选项,文档生成器(DoxyBlocks)将从自动版本(Autoversion)头文件中提取版本号.\n使用的格式是主版本.副版本.构建版本(MAJOR.MINOR.BUILD).\n如果项目未启用自动版本控制,则禁用此选项."));
    BoxSizer5->Add(CheckBoxUseAutoVersion, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    StaticBoxSizer2->Add(BoxSizer5, 0, wxEXPAND, 5);
    BoxSizer18 = new wxBoxSizer(wxHORIZONTAL);
    StaticText8 = new wxStaticText(Panel3, wxID_ANY, wxT("输出目录"), wxDefaultPosition, wxDefaultSize, 0, _T("wxID_ANY"));
    BoxSizer18->Add(StaticText8, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    TextCtrlOutputDirectory = new wxTextCtrl(Panel3, ID_TEXTCTRLOUTPUT_DIRECTORY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_TEXTCTRLOUTPUT_DIRECTORY"));
    //TextCtrlOutputDirectory->SetToolTip(wxT("The OUTPUT_DIRECTORY tag is used to specify the (relative or\nabsolute) base path where the generated documentation will be put.\nIf a relative path is entered, it will be relative to the location\nwhere doxygen was started. If left blank the current directory will be used.\n\nDoxyBlocks will use the path name entered here to create a directory\nrelative to <project dir>. This allows you to create separate doxygen\ndirectories for projects that reside in the same directory, or just use a\ndifferent directory name. If this field is blank, documents will be created\nin <project dir>/doxygen. Enter directory names without dots, \nleading separators, volume names, etc. DoxyBlocks does validation on\nthe path name and will strip extraneous characters.\n\nExamples:\n[blank]                     -> <project dir>/doxygen.\n\"docs\"                      -> <project dir>/docs.\n\"docs/sub1/sub2\"  -> <project dir>/docs/sub1/sub2.\n\"doxygen/docs\"     -> <project dir>/doxygen/docs.\n"));
    TextCtrlOutputDirectory->SetToolTip(wxT("输出目录标记用于指定(相对或绝对)基本路径,生成的文档将放在其中.\n如果输入了相对路径,则该路径将相对于doxygen的启动位置.\n如果留空,将使用当前目录.\n文档生成器(DoxyBlocks)将使用此处输入的路径名创建一个相对于<项目目录(Project DIr)>的目录.\n这允许您为驻留在同一目录中的项目创建单独的doxygen目录,或者只使用不同的目录名.\n如果此字段为空,则将在<项目目录(Project Dir)>/doxygen中创建文档.\n输入不带点的目录名,前导分隔符,卷名等.\n文档生成器(DoxyBlocks)对路径名进行验证,并删除无关字符.\n示例：\n[空白(blank)]-><project dir>/doxygen.\n\"文档(docs)\"-><project dir>/docs.\n\"docs/sub1/sub2\"-><project dir>/docs/sub1/sub2.\n\"doxygen/docs\"-><project dir>/doxygen/docs."));
    BoxSizer18->Add(TextCtrlOutputDirectory, 2, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    StaticBoxSizer2->Add(BoxSizer18, 0, wxEXPAND, 5);
    BoxSizer20 = new wxBoxSizer(wxHORIZONTAL);
    StaticText5 = new wxStaticText(Panel3, ID_STATICTEXT5, wxT("输出语言"), wxDefaultPosition, wxDefaultSize, 0, _T("ID_STATICTEXT5"));
    BoxSizer20->Add(StaticText5, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    ChoiceOutputLanguage = new wxChoice(Panel3, ID_CHOICE_OUTPUT_LANGUAGE, wxDefaultPosition, wxDefaultSize, 0, 0, 0, wxDefaultValidator, _T("ID_CHOICE_OUTPUT_LANGUAGE"));
    ChoiceOutputLanguage->Append(wxT("Afrikaans"));
    ChoiceOutputLanguage->Append(wxT("Arabic"));
    ChoiceOutputLanguage->Append(wxT("Brazilian"));
    ChoiceOutputLanguage->Append(wxT("Catalan"));
    ChoiceOutputLanguage->Append(wxT("Chinese"));
    ChoiceOutputLanguage->Append(wxT("Chinese-Traditional"));
    ChoiceOutputLanguage->Append(wxT("Croatian"));
    ChoiceOutputLanguage->Append(wxT("Czech"));
    ChoiceOutputLanguage->Append(wxT("Danish"));
    ChoiceOutputLanguage->Append(wxT("Dutch"));
    ChoiceOutputLanguage->Append(wxT("English"));
    ChoiceOutputLanguage->Append(wxT("Esperanto"));
    ChoiceOutputLanguage->Append(wxT("Farsi"));
    ChoiceOutputLanguage->Append(wxT("Finnish"));
    ChoiceOutputLanguage->Append(wxT("French"));
    ChoiceOutputLanguage->Append(wxT("German"));
    ChoiceOutputLanguage->Append(wxT("Greek"));
    ChoiceOutputLanguage->Append(wxT("Hungarian"));
    ChoiceOutputLanguage->Append(wxT("Italian"));
    ChoiceOutputLanguage->Append(wxT("Japanese"));
    ChoiceOutputLanguage->Append(wxT("Japanese-en"));
    ChoiceOutputLanguage->Append(wxT("Korean"));
    ChoiceOutputLanguage->Append(wxT("Korean-en"));
    ChoiceOutputLanguage->Append(wxT("Lithuanian"));
    ChoiceOutputLanguage->Append(wxT("Norwegian"));
    ChoiceOutputLanguage->Append(wxT("Macedonian"));
    ChoiceOutputLanguage->Append(wxT("Persian"));
    ChoiceOutputLanguage->Append(wxT("Polish"));
    ChoiceOutputLanguage->Append(wxT("Portuguese"));
    ChoiceOutputLanguage->Append(wxT("Romanian"));
    ChoiceOutputLanguage->Append(wxT("Russian"));
    ChoiceOutputLanguage->Append(wxT("Serbian"));
    ChoiceOutputLanguage->Append(wxT("Serbian-Cyrilic"));
    ChoiceOutputLanguage->Append(wxT("Slovak,"));
    ChoiceOutputLanguage->Append(wxT("Slovene"));
    ChoiceOutputLanguage->Append(wxT("Spanish"));
    ChoiceOutputLanguage->Append(wxT("Swedish"));
    ChoiceOutputLanguage->Append(wxT("Ukrainian"));
    ChoiceOutputLanguage->Append(wxT("Vietnamese"));
    //ChoiceOutputLanguage->SetToolTip(wxT("The OUTPUT_LANGUAGE tag is used to specify the language in which all\ndocumentation generated by doxygen is written. Doxygen will use this\ninformation to generate all constant output in the proper language.\nThe default language is English, other supported languages are:\nAfrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional,\nCroatian, Czech, Danish, Dutch, Esperanto, Farsi, Finnish, French, German,\nGreek, Hungarian, Italian, Japanese, Japanese-en (Japanese with English\nmessages), Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian,\nPolish, Portuguese, Romanian, Russian, Serbian, Serbian-Cyrilic, Slovak,\nSlovene, Spanish, Swedish, Ukrainian, and Vietnamese."));
    ChoiceOutputLanguage->SetToolTip(wxT("输出语言标记用于指定编写doxygen生成的所有文档的语言.\nDoxygen将使用此信息以正确的语言生成所有常量输出.\n默认语言为英语,其他支持的语言为:\n南非荷兰语,阿拉伯语,巴西语,加泰罗尼亚语,中文,繁体中文,\n克罗地亚语,捷克语,丹麦语,荷兰语,世界语,波斯语,芬兰语,法语,德语,\n希腊语,匈牙利语,意大利语,日语,日语_en(带英语信息的日语),\n朝鲜语,朝鲜语,立陶宛语,挪威语,马其顿语,波斯语,\n波兰语,葡萄牙语,罗马尼亚语,俄语,塞尔维亚语,塞尔维亚西里尔语,斯洛伐克语,\n斯洛文尼亚语,西班牙语,瑞典语,乌克兰语和越南语."));
    BoxSizer20->Add(ChoiceOutputLanguage, 2, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    StaticBoxSizer2->Add(BoxSizer20, 0, wxALIGN_LEFT, 5);
    BoxSizer4->Add(StaticBoxSizer2, 0, wxEXPAND, 5);
    StaticBoxSizer5 = new wxStaticBoxSizer(wxVERTICAL, Panel3, wxT("构建"));
    CheckBoxExtractAll = new wxCheckBox(Panel3, ID_CHECKBOX_EXTRACT_ALL, wxT("全部提取"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_EXTRACT_ALL"));
    CheckBoxExtractAll->SetValue(false);
    //CheckBoxExtractAll->SetToolTip(wxT("If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in\ndocumentation are documented, even if no documentation was available.\nPrivate class members and static file members will be hidden unless\nthe EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES"));
    CheckBoxExtractAll->SetToolTip(wxT("如果全部提取标记设置为是(YES),doxygen将假定文档中的所有实体都有文档,即使没有可用的文档.\n私有类成员和静态文件成员将被隐藏,除非提取私有类成员和提取静态标记设置为是(YES)"));
    StaticBoxSizer5->Add(CheckBoxExtractAll, 1, wxTOP|wxLEFT|wxRIGHT, 5);
    CheckBoxExtractPrivate = new wxCheckBox(Panel3, ID_CHECKBOX_EXTRACTPRIVATE, wxT("提取私有类成员"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_EXTRACTPRIVATE"));
    CheckBoxExtractPrivate->SetValue(false);
    CheckBoxExtractPrivate->SetToolTip(wxT("如果提取私有类成员标记设置为是(YES),则文档中将包括类的所有私有成员."));
    StaticBoxSizer5->Add(CheckBoxExtractPrivate, 1, wxTOP|wxLEFT|wxRIGHT, 5);
    CheckBoxExtractStatic = new wxCheckBox(Panel3, ID_CHECKBOX_EXTRACTSTATIC, wxT("提取静态"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_EXTRACTSTATIC"));
    CheckBoxExtractStatic->SetValue(false);
    CheckBoxExtractStatic->SetToolTip(wxT("如果提取静态标记设置为YES,则文档中将包括文件的所有静态成员."));
    StaticBoxSizer5->Add(CheckBoxExtractStatic, 1, wxALL, 5);
    BoxSizer4->Add(StaticBoxSizer5, 0, wxEXPAND, 5);
    StaticBoxSizer10 = new wxStaticBoxSizer(wxVERTICAL, Panel3, wxT("警告"));
    CheckBoxWarnings = new wxCheckBox(Panel3, ID_CHECKBOX_WARNINGS, wxT("警告"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_WARNINGS"));
    CheckBoxWarnings->SetValue(false);
    CheckBoxWarnings->SetToolTip(wxT("警告标签可用于打开/关闭doxygen生成的警告消息."));
    StaticBoxSizer10->Add(CheckBoxWarnings, 0, wxALL|wxALIGN_LEFT, 5);
    BoxSizer11 = new wxBoxSizer(wxVERTICAL);
    CheckBoxWarnIfDocError = new wxCheckBox(Panel3, ID_CHECKBOX_WARN_IF_DOC_ERROR, wxT("如果文档出错发出警告"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_WARN_IF_DOC_ERROR"));
    CheckBoxWarnIfDocError->SetValue(false);
    //CheckBoxWarnIfDocError->SetToolTip(wxT("If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for\npotential errors in the documentation, such as not documenting some\nparameters in a documented function, or documenting parameters that\ndon\'t exist or using markup commands wrongly."));
    CheckBoxWarnIfDocError->SetToolTip(wxT("如果'如果文档出错发出警告'设置为是(YES),\ndoxygen将为文档中的潜在错误生成警告,例如未在文档化函数中记录某些参数,\n或记录不存在的参数或错误地使用标记命令."));
    BoxSizer11->Add(CheckBoxWarnIfDocError, 1, wxTOP|wxLEFT|wxRIGHT, 5);
    CheckBoxWarnIfUndocumented = new wxCheckBox(Panel3, ID_CHECKBOX_WARN_IF_UNDOCUMENTED, wxT("如果未文档化则警告"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_WARN_IF_UNDOCUMENTED"));
    CheckBoxWarnIfUndocumented->SetValue(false);
    CheckBoxWarnIfUndocumented->SetToolTip(wxT("如果'如果未文档化则警告'设置为是(YES),则doxygen将为未记录的成员生成警告.\n如果'全部提取'设置为是(YES),则此标志将自动禁用."));
    BoxSizer11->Add(CheckBoxWarnIfUndocumented, 1, wxTOP|wxLEFT|wxRIGHT, 5);
    CheckBoxWarnNoParamdoc = new wxCheckBox(Panel3, ID_CHECKBOX_WARN_NO_PARAMDOC, wxT("警告无参数文档"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_WARN_NO_PARAMDOC"));
    CheckBoxWarnNoParamdoc->SetValue(false);
    //CheckBoxWarnNoParamdoc->SetToolTip(wxT("This WARN_NO_PARAMDOC option can be abled to get warnings for\nfunctions that are documented, but have no documentation for their parameters\nor return value. If set to NO (the default) doxygen will only warn about\nwrong or incomplete parameter documentation, but not about the absence of\ndocumentation."));
    CheckBoxWarnNoParamdoc->SetToolTip(wxT("此'警告无参数文档'选项可用于获取已记录的函数的警告,\n但没有其参数或返回值的文档.如果设置为否(NO)(默认值),\ndoxygen只会警告错误或不完整的参数文档,而不会警告缺少文档."));
    BoxSizer11->Add(CheckBoxWarnNoParamdoc, 1, wxALL, 5);
    StaticBoxSizer10->Add(BoxSizer11, 0, wxEXPAND, 5);
    BoxSizer4->Add(StaticBoxSizer10, 0, wxTOP|wxLEFT|wxRIGHT|wxEXPAND, 5);
    StaticBoxSizer6 = new wxStaticBoxSizer(wxVERTICAL, Panel3, wxT("字母分类索引"));
    CheckBoxAlphabeticalIndex = new wxCheckBox(Panel3, ID_CHECKBOX_ALPHABETICAL_INDEX, wxT("字母索引"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_ALPHABETICAL_INDEX"));
    CheckBoxAlphabeticalIndex->SetValue(false);
    CheckBoxAlphabeticalIndex->SetToolTip(wxT("如果'字母索引'标记设置为是(YES),则将生成所有复合的字母索引.\n如果项目包含许多类,结构,联合或接口,请启用此选项."));
    StaticBoxSizer6->Add(CheckBoxAlphabeticalIndex, 1, wxALL|wxALIGN_LEFT, 5);
    BoxSizer4->Add(StaticBoxSizer6, 0, wxALL|wxEXPAND, 5);
    Panel3->SetSizer(BoxSizer4);
    BoxSizer4->Fit(Panel3);
    BoxSizer4->SetSizeHints(Panel3);
    Panel4 = new wxPanel(NotebookPrefs, ID_PANEL4, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL, _T("ID_PANEL4"));
    BoxSizer16 = new wxBoxSizer(wxVERTICAL);
    StaticBoxSizer7 = new wxStaticBoxSizer(wxVERTICAL, Panel4, wxT("输出"));
    BoxSizer12 = new wxBoxSizer(wxVERTICAL);
    CheckBoxGenerateHTML = new wxCheckBox(Panel4, ID_CHECKBOX_GENERATE_HTML, wxT("生成超文本(HTML)"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_GENERATE_HTML"));
    CheckBoxGenerateHTML->SetValue(true);
    CheckBoxGenerateHTML->SetToolTip(wxT("如果'生成超文本'标记设置为是(YES)(默认),Doxygen将生成HTML输出."));
    BoxSizer12->Add(CheckBoxGenerateHTML, 0, wxALL|wxALIGN_LEFT, 5);
    BoxSizer17 = new wxBoxSizer(wxVERTICAL);
    CheckBoxGenerateHTMLHelp = new wxCheckBox(Panel4, ID_CHECKBOX_GENERATE_HTMLHELP, wxT("生成超文本帮助"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_GENERATE_HTMLHELP"));
    CheckBoxGenerateHTMLHelp->SetValue(false);
    CheckBoxGenerateHTMLHelp->SetToolTip(wxT("如果'生成超文本帮助'标记设置为是(YES),则将生成其他索引文件,\n这些文件可以用作诸如Microsoft HTML Help Workshop之类的工具的输入,\n以生成生成的HTML文档的编译HTML帮助文件(.chm)."));
    BoxSizer17->Add(CheckBoxGenerateHTMLHelp, 1, wxTOP|wxLEFT|wxRIGHT, 5);
    CheckBoxGenerateCHI = new wxCheckBox(Panel4, ID_CHECKBOX_GENERATE_CHI, wxT("生成超文本索引"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_GENERATE_CHI"));
    CheckBoxGenerateCHI->SetValue(false);
    CheckBoxGenerateCHI->SetToolTip(wxT("如果'生成超文本帮助'标记设置为是(YES),则'生成超文本索引'标志将控制是否生成单独的.CHI索引文件:是(YES)或是否应将其包含在主(.chm)文件中:否(NO)"));
    BoxSizer17->Add(CheckBoxGenerateCHI, 1, wxTOP|wxLEFT|wxRIGHT, 5);
    CheckBoxBinaryTOC = new wxCheckBox(Panel4, ID_CHECKBOX_BINARY_TOC, wxT("二进制目录"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_BINARY_TOC"));
    CheckBoxBinaryTOC->SetValue(false);
    //CheckBoxBinaryTOC->SetToolTip(wxT("If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag\ncontrols whether a binary table of contents is generated (YES) or a\nnormal table of contents (NO) in the .chm file."));
    CheckBoxBinaryTOC->SetToolTip(wxT("如果'生成超文本帮助'标记设置为是(YES),\n'二进制目录'标志将控制在(.chm)文件中生成的是二进制目录:是(YES),\n还是普通目录:否(NO)."));
    BoxSizer17->Add(CheckBoxBinaryTOC, 1, wxALL, 5);
    BoxSizer12->Add(BoxSizer17, 0, wxALIGN_LEFT, 5);
    StaticBoxSizer7->Add(BoxSizer12, 0, wxALIGN_LEFT, 5);
    BoxSizer14 = new wxBoxSizer(wxVERTICAL);
    CheckBoxGenerateLatex = new wxCheckBox(Panel4, ID_CHECKBOX_GENERATE_LATEX, wxT("生成LATEX文档"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_GENERATE_LATEX"));
    CheckBoxGenerateLatex->SetValue(false);
    CheckBoxGenerateLatex->SetToolTip(wxT("如果'生成LATEX文档'标签设置为YES(默认),Doxygen将生成LATEX输出."));
    BoxSizer14->Add(CheckBoxGenerateLatex, 1, wxTOP|wxLEFT|wxRIGHT, 5);
    CheckBoxGenerateRTF = new wxCheckBox(Panel4, ID_CHECKBOX_GENERATE_RTF, wxT("生成RTF文件"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_GENERATE_RTF"));
    CheckBoxGenerateRTF->SetValue(false);
    CheckBoxGenerateRTF->SetToolTip(wxT("如果'生成RTF文件'标记设置为是(YES),Doxygen将生成RTF文件输出.\nRTF输出针对Word97进行了优化,在其他RTF阅读器或编辑器中可能看起来不太好看."));
    BoxSizer14->Add(CheckBoxGenerateRTF, 1, wxTOP|wxLEFT|wxRIGHT, 5);
    CheckBoxGenerateMan = new wxCheckBox(Panel4, ID_CHECKBOX_GENERATE_MAN, wxT("生成手册页"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_GENERATE_MAN"));
    CheckBoxGenerateMan->SetValue(true);
    CheckBoxGenerateMan->SetToolTip(wxT("如果'生成手册页'(手册页用于是Unix或类Unix的一种帮助文档)标记设置为是(YES)(默认),Doxygen将生成手册页"));
    BoxSizer14->Add(CheckBoxGenerateMan, 1, wxALL, 5);
    StaticBoxSizer7->Add(BoxSizer14, 0, wxALIGN_LEFT, 5);
    BoxSizer15 = new wxBoxSizer(wxVERTICAL);
    CheckBoxGenerateXML = new wxCheckBox(Panel4, ID_CHECKBOX_GENERATE_XML, wxT("生成XML文档"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_GENERATE_XML"));
    CheckBoxGenerateXML->SetValue(false);
    CheckBoxGenerateXML->SetToolTip(wxT("如果'生成XML文档'标记设置为是(YES),Doxygen将生成一个XML文件,该文件捕获包括所有文档的代码结构."));
    BoxSizer15->Add(CheckBoxGenerateXML, 1, wxTOP|wxLEFT|wxRIGHT, 5);
    CheckBoxGenerateAutogenDef = new wxCheckBox(Panel4, ID_CHECKBOX_GENERATE_AUTOGEN_DEF, wxT("生成AUTOGEN定义文件"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_GENERATE_AUTOGEN_DEF"));
    CheckBoxGenerateAutogenDef->SetValue(false);
    CheckBoxGenerateAutogenDef->SetToolTip(wxT("如果'生成AUTOGEN定义文件'标记设置为是YES,Doxygen将生成一个AUTOGEN定义(请参见autogen.sf.net)文件,该文件捕获包括所有文档在内的代码结构.\n请注意,此功能目前仍处于实验阶段,不完整."));
    BoxSizer15->Add(CheckBoxGenerateAutogenDef, 1, wxTOP|wxLEFT|wxRIGHT, 5);
    CheckBoxGeneratePerlMod = new wxCheckBox(Panel4, ID_CHECKBOX_GENERATE_PERLMOD, wxT("生成Perl模块"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_GENERATE_PERLMOD"));
    CheckBoxGeneratePerlMod->SetValue(false);
    CheckBoxGeneratePerlMod->SetToolTip(wxT("如果'Perl模块'标记设置为是(YES),Doxygen将生成一个Perl模块文件,该文件捕获包括所有文档在内的代码结构.\n请注意,此功能目前仍处于实验阶段,不完整."));
    BoxSizer15->Add(CheckBoxGeneratePerlMod, 1, wxALL, 5);
    StaticBoxSizer7->Add(BoxSizer15, 0, wxALIGN_LEFT, 5);
    BoxSizer16->Add(StaticBoxSizer7, 0, wxEXPAND, 5);
    StaticBoxSizer8 = new wxStaticBoxSizer(wxHORIZONTAL, Panel4, wxT("预处理器"));
    CheckBoxEnablePreprocessing = new wxCheckBox(Panel4, ID_CHECKBOX_ENABLE_PREPROCESSING, wxT("启用预处理"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_ENABLE_PREPROCESSING"));
    CheckBoxEnablePreprocessing->SetValue(false);
    CheckBoxEnablePreprocessing->SetToolTip(wxT("如果'启用预处理'标记设置为是(YES)(默认值),Doxygen将计算源文件中找到的所有C预处理器指令并包含文件."));
    StaticBoxSizer8->Add(CheckBoxEnablePreprocessing, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    BoxSizer16->Add(StaticBoxSizer8, 0, wxEXPAND, 5);
    StaticBoxSizer9 = new wxStaticBoxSizer(wxVERTICAL, Panel4, wxT("点(DOT)图[用于由DOT脚本语言生成诸如SVG的图片]"));
    CheckBoxClassDiagrams = new wxCheckBox(Panel4, ID_CHECKBOX_CLASS_DIAGRAMS, wxT("类图"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_CLASS_DIAGRAMS"));
    CheckBoxClassDiagrams->SetValue(false);
    CheckBoxClassDiagrams->SetToolTip(wxT("如果'类图'标记设置为是(YES)(默认值),Doxygen将为具有基类或超级类的类生成继承关系图(在HTML,RTF和LaTeX中).\n将标记设置为'否(NO)'将关闭图表.\n请注意,下面的'有点'选项取代了此选项.这只是个让步.\n建议安装并使用'点',因为它可以生成更强大的图形."));
    StaticBoxSizer9->Add(CheckBoxClassDiagrams, 1, wxALL, 5);
    CheckBoxHaveDot = new wxCheckBox(Panel4, ID_CHECKBOX_HAVE_DOT, wxT("存在(DOT)点图程序"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_HAVE_DOT"));
    CheckBoxHaveDot->SetValue(false);
    CheckBoxHaveDot->SetToolTip(wxT("如果将'存在(DOT)点图程序'标记设置为是(YES),则doxygen将假定路径中有DOT工具可用.这个工具是Graphviz的一部分,Graphviz是AT&T和朗讯贝尔实验室的图形可视化工具包.\n如果此选项设置为'否(NO)'(默认设置),则此部分中的其他选项无效"));
    StaticBoxSizer9->Add(CheckBoxHaveDot, 1, wxALL, 5);
    BoxSizer16->Add(StaticBoxSizer9, 0, wxEXPAND, 5);
    Panel4->SetSizer(BoxSizer16);
    BoxSizer16->Fit(Panel4);
    BoxSizer16->SetSizeHints(Panel4);
    Panel1 = new wxPanel(NotebookPrefs, ID_PANEL1, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL, _T("ID_PANEL1"));
    BoxSizer7 = new wxBoxSizer(wxVERTICAL);
    StaticBoxSizer4 = new wxStaticBoxSizer(wxVERTICAL, Panel1, wxT("路径"));
    BoxSizer8 = new wxBoxSizer(wxHORIZONTAL);
    StaticText2 = new wxStaticText(Panel1, ID_STATICTEXT2, wxT("doxygen路径"), wxDefaultPosition, wxDefaultSize, 0, _T("ID_STATICTEXT2"));
    BoxSizer8->Add(StaticText2, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    TextCtrlPathDoxygen = new wxTextCtrl(Panel1, ID_TEXTCTRL_PATHDOXYGEN, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_TEXTCTRL_PATHDOXYGEN"));
    TextCtrlPathDoxygen->SetToolTip(wxT("doxygen可执行文件的路径.\n如果此字段为空,文档生成器将假定doxygen在环境路径中的某个位置可用.\n您可以在路径中使用诸如$(CODEBLOCKS)等宏,它们将自动展开."));
    BoxSizer8->Add(TextCtrlPathDoxygen, 3, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    ButtonBrowseDoxygen = new wxButton(Panel1, ID_BUTTON_BROWSEDOXYGEN, wxT("浏览"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_BUTTON_BROWSEDOXYGEN"));
    ButtonBrowseDoxygen->SetToolTip(wxT("浏览doxygen."));
    BoxSizer8->Add(ButtonBrowseDoxygen, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    StaticBoxSizer4->Add(BoxSizer8, 0, wxEXPAND, 5);
    BoxSizer9 = new wxBoxSizer(wxHORIZONTAL);
    StaticText4 = new wxStaticText(Panel1, ID_STATICTEXT4, wxT("文档向导目录"), wxDefaultPosition, wxDefaultSize, 0, _T("ID_STATICTEXT4"));
    BoxSizer9->Add(StaticText4, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    TextCtrlPathDoxywizard = new wxTextCtrl(Panel1, ID_TEXTCTRL_PATHDOXYWIZARD, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_TEXTCTRL_PATHDOXYWIZARD"));
    TextCtrlPathDoxywizard->SetToolTip(wxT("文档向导(doxywizard)可执行文件的路径.\n如果此字段为空,文档生成器(DoxyBlocks)将假定文档向导(doxywizard)在环境路径中的某个位置可用.\n您可以在路径中使用诸如$(CODEBLOCKS)等宏,它们将自动展开."));
    BoxSizer9->Add(TextCtrlPathDoxywizard, 3, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    ButtonBrowseDoxywizard = new wxButton(Panel1, ID_BUTTON_BROWSEDOXYWIZARD, wxT("浏览"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_BUTTON_BROWSEDOXYWIZARD"));
    ButtonBrowseDoxywizard->SetToolTip(wxT("浏览文档向导(doxywizard)."));
    BoxSizer9->Add(ButtonBrowseDoxywizard, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    StaticBoxSizer4->Add(BoxSizer9, 0, wxEXPAND, 5);
    BoxSizer3 = new wxBoxSizer(wxHORIZONTAL);
    StaticText3 = new wxStaticText(Panel1, ID_STATICTEXT3, wxT("HTML帮助编译器(HHC)目录"), wxDefaultPosition, wxDefaultSize, 0, _T("ID_STATICTEXT3"));
    BoxSizer3->Add(StaticText3, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    TextCtrlPathHHC = new wxTextCtrl(Panel1, ID_TEXTCTRL_PATHHHC, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_TEXTCTRL_PATHHHC"));
    TextCtrlPathHHC->SetToolTip(wxT("HTML帮助编译器可执行文件的路径.\n如果此字段为空,DoxyBlocks将假定HHC在环境路径中的某个位置可用.\n您可以在路径中使用诸如$(CODEBLOCKS)等宏,它们将自动展开."));
    BoxSizer3->Add(TextCtrlPathHHC, 3, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    ButtonBrowseHHC = new wxButton(Panel1, ID_BUTTON_BROWSEHHC, wxT("浏览"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_BUTTON_BROWSEHHC"));
    ButtonBrowseHHC->SetToolTip(wxT("浏览HTML帮助编译器(HHC)目录."));
    BoxSizer3->Add(ButtonBrowseHHC, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    StaticBoxSizer4->Add(BoxSizer3, 0, wxEXPAND, 5);
    BoxSizer13 = new wxBoxSizer(wxHORIZONTAL);
    StaticText6 = new wxStaticText(Panel1, ID_STATICTEXT6, wxT("点图(Dot)程序目录"), wxDefaultPosition, wxDefaultSize, 0, _T("ID_STATICTEXT6"));
    BoxSizer13->Add(StaticText6, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    TextCtrlPathDot = new wxTextCtrl(Panel1, ID_TEXTCTRL_PATHDOT, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_TEXTCTRL_PATHDOT"));
    TextCtrlPathDot->SetToolTip(wxT("点图(Dot)可执行文件的路径.\n如果此字段为空,DoxyBlocks将假定点图(Dot)在环境路径中的某个位置可用.\n您可以在路径中使用诸如$(CODEBLOCKS)等宏,它们将自动展开."));
    BoxSizer13->Add(TextCtrlPathDot, 3, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    ButtonBrowseDot = new wxButton(Panel1, ID_BUTTON_BROWSEDOT, wxT("浏览"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_BUTTON_BROWSEDOT"));
    ButtonBrowseDot->SetToolTip(wxT("浏览点图(Dot)目录."));
    BoxSizer13->Add(ButtonBrowseDot, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    StaticBoxSizer4->Add(BoxSizer13, 0, wxEXPAND, 5);
    BoxSizer19 = new wxBoxSizer(wxHORIZONTAL);
    StaticText7 = new wxStaticText(Panel1, ID_STATICTEXT7, wxT("CHM查看器目录"), wxDefaultPosition, wxDefaultSize, 0, _T("ID_STATICTEXT7"));
    BoxSizer19->Add(StaticText7, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    TextCtrlPathCHMViewer = new wxTextCtrl(Panel1, ID_TEXTCTRL_PATHCHMVIEWER, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_TEXTCTRL_PATHCHMVIEWER"));
    TextCtrlPathCHMViewer->SetToolTip(wxT("CHM查看器可执行文件的路径.\n如果此字段为空,DoxyBlocks将假定CHM查看器在环境路径中的某个位置可用.\n您可以在路径中使用诸如$(CODEBLOCKS)等宏,它们将自动展开."));
    BoxSizer19->Add(TextCtrlPathCHMViewer, 3, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    ButtonBrowseCHMViewer = new wxButton(Panel1, ID_BUTTON_BROWSECHMVIEWER, wxT("浏览"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_BUTTON_BROWSECHMVIEWER"));
    ButtonBrowseCHMViewer->SetToolTip(wxT("浏览CHM查看器."));
    BoxSizer19->Add(ButtonBrowseCHMViewer, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    StaticBoxSizer4->Add(BoxSizer19, 0, wxEXPAND, 5);
    BoxSizer7->Add(StaticBoxSizer4, 0, wxEXPAND, 5);
    StaticBoxSizer11 = new wxStaticBoxSizer(wxVERTICAL, Panel1, wxT("通用选项"));
    BoxSizer21 = new wxBoxSizer(wxVERTICAL);
    CheckBoxOverwriteDoxyfile = new wxCheckBox(Panel1, ID_CHECKBOX_OVERWRITEDOXYFILE, wxT("覆盖(Doxy)文档"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_OVERWRITEDOXYFILE"));
    CheckBoxOverwriteDoxyfile->SetValue(false);
    CheckBoxOverwriteDoxyfile->SetToolTip(wxT("允许文档生成器(DoxyBlocks)覆盖(doxy)文件.\n默认情况下,如果(doxy)文件已经存在,则不会覆盖它以保护在文档生成器(DoxyBlocks)之外所做的任何更改,\n但是此行为会阻止在文档生成器(DoxyBlocks)内所做的更改写入现有的(doxy)文件."));
    BoxSizer21->Add(CheckBoxOverwriteDoxyfile, 1, wxALL, 5);
    CheckBoxPromptBeforeOverwriting = new wxCheckBox(Panel1, ID_CHECKBOX_PROMPTB4OVERWRITING, wxT("覆盖前提示"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_PROMPTB4OVERWRITING"));
    CheckBoxPromptBeforeOverwriting->SetValue(false);
    CheckBoxPromptBeforeOverwriting->SetToolTip(wxT("在覆盖现有(doxy)文件之前提示.\n当与'覆盖(Doxy)文档'一起使用时,此设置强制.\n文档生成器(DoxyBlocks)在覆盖现有(doxy)文件之前提示您."));
    BoxSizer21->Add(CheckBoxPromptBeforeOverwriting, 1, wxALL, 5);
    CheckBoxUseAtInTags = new wxCheckBox(Panel1, ID_CHECKBOX_USEATINTAGS, wxT("在标记中使用'@'符号"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_USEATINTAGS"));
    CheckBoxUseAtInTags->SetValue(false);
    CheckBoxUseAtInTags->SetToolTip(wxT("在文档标记中使用'@'符号,而不是反斜杆('\\')符号.\n此选项使文档生成器(DoxyBlocks)创建文档标记,如'@brief'和'@param',而不是'\\brief'和'\\param'."));
    BoxSizer21->Add(CheckBoxUseAtInTags, 1, wxALL, 5);
    StaticBoxSizer11->Add(BoxSizer21, 1, wxEXPAND, 5);
    BoxSizer22 = new wxBoxSizer(wxHORIZONTAL);
    CheckBoxLoadTemplate = new wxCheckBox(Panel1, ID_CHECKBOX_LOADTEMPLATE, wxT("如果不存在保存的设置,则加载设置模板"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_LOADTEMPLATE"));
    CheckBoxLoadTemplate->SetValue(false);
    CheckBoxLoadTemplate->SetToolTip(wxT("此选项允许您将首选设置用作默认设置,方法是加载以前保存的设置模板(如果存在),\n而不是在加载不包含已保存的文档生成器(DoxyBlocks)设置的项目时使用系统默认设置.\n如果找不到模板,文档生成器(DoxyBlocks)将返回默认设置."));
    BoxSizer22->Add(CheckBoxLoadTemplate, 1, wxALL|wxALIGN_CENTER_VERTICAL, 5);
    StaticBoxSizer11->Add(BoxSizer22, 0, wxEXPAND, 5);
    BoxSizer7->Add(StaticBoxSizer11, 0, wxEXPAND, 5);
    StaticBoxSizer12 = new wxStaticBoxSizer(wxVERTICAL, Panel1, wxT("超文本(HTML)"));
    CheckBoxUseInternalViewer = new wxCheckBox(Panel1, ID_CHECKBOX_USEINTERNALVIEWER, wxT("使用内部查看器"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_USEINTERNALVIEWER"));
    CheckBoxUseInternalViewer->SetValue(false);
    CheckBoxUseInternalViewer->SetToolTip(wxT("使用内部查看器查看HTML文档.\n如果未设置此选项,则文档生成器(DoxyBlocks)将使用系统的默认浏览器.\n如果未设置'生成HTML',则此设置无效."));
    StaticBoxSizer12->Add(CheckBoxUseInternalViewer, 1, wxALL, 5);
    CheckBoxRunHTML = new wxCheckBox(Panel1, ID_CHECKBOX_RUNHTML, wxT("编译后运行HTML"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_RUNHTML"));
    CheckBoxRunHTML->SetValue(false);
    CheckBoxRunHTML->SetToolTip(wxT("编译后运行HTML文档.\n如果设置了'使用内部查看器',文档生成器(DoxyBlocks)将使用Code::Blocks的内部查看器.\n否则,它将使用系统的默认浏览器.\n如果未设置'生成HTML',则此设置无效."));
    StaticBoxSizer12->Add(CheckBoxRunHTML, 1, wxALL, 5);
    CheckBoxRunCHM = new wxCheckBox(Panel1, ID_CHECKBOX_RUNCHM, wxT("编译后运行CHM"), wxDefaultPosition, wxDefaultSize, 0, wxDefaultValidator, _T("ID_CHECKBOX_RUNCHM"));
    CheckBoxRunCHM->SetValue(false);
    CheckBoxRunCHM->SetToolTip(wxT("编译后运行编译的帮助(CHM).\n此设置当前仅对Windows有效.\n如果不存在CHM文件,则忽略此设置.\n如果未设置'生成HTML',则此设置无效."));
    StaticBoxSizer12->Add(CheckBoxRunCHM, 1, wxALL, 5);
    BoxSizer7->Add(StaticBoxSizer12, 0, wxEXPAND, 5);
    Panel1->SetSizer(BoxSizer7);
    BoxSizer7->Fit(Panel1);
    BoxSizer7->SetSizeHints(Panel1);
    NotebookPrefs->AddPage(Panel2, wxT("注释风格"), false);
    NotebookPrefs->AddPage(Panel3, wxT("默认文档(Doxy)"), false);
    NotebookPrefs->AddPage(Panel4, wxT("默认文档2(Doxy)"), false);
    NotebookPrefs->AddPage(Panel1, wxT("通用"), false);
    BoxSizer1->Add(NotebookPrefs, 1, wxALL|wxEXPAND, 5);
    SetSizer(BoxSizer1);
    BoxSizer1->Fit(this);
    BoxSizer1->SetSizeHints(this);

    Connect(ID_RADIOBOX_BLOCKCOMMENTS,wxEVT_COMMAND_RADIOBOX_SELECTED,(wxObjectEventFunction)&ConfigPanel::OnRadioBoxBlockCommentsSelect);
    Connect(ID_RADIOBOX_LINECOMMENTS,wxEVT_COMMAND_RADIOBOX_SELECTED,(wxObjectEventFunction)&ConfigPanel::OnRadioBoxLineCommentsSelect);
    Connect(ID_CHECKBOX_USEAUTOVERSION,wxEVT_COMMAND_CHECKBOX_CLICKED,(wxObjectEventFunction)&ConfigPanel::OnCheckBoxUseAutoversionClick);
    Connect(ID_CHECKBOX_WARNINGS,wxEVT_COMMAND_CHECKBOX_CLICKED,(wxObjectEventFunction)&ConfigPanel::OnCheckBoxWarningsClick);
    Connect(ID_CHECKBOX_GENERATE_HTML,wxEVT_COMMAND_CHECKBOX_CLICKED,(wxObjectEventFunction)&ConfigPanel::OnCheckBoxGenerateHTMLClick);
    Connect(ID_BUTTON_BROWSEDOXYGEN,wxEVT_COMMAND_BUTTON_CLICKED,(wxObjectEventFunction)&ConfigPanel::OnButtonBrowseDoxygenClick);
    Connect(ID_BUTTON_BROWSEDOXYWIZARD,wxEVT_COMMAND_BUTTON_CLICKED,(wxObjectEventFunction)&ConfigPanel::OnButtonBrowseDoxywizardClick);
    Connect(ID_BUTTON_BROWSEHHC,wxEVT_COMMAND_BUTTON_CLICKED,(wxObjectEventFunction)&ConfigPanel::OnButtonBrowseHHCClick);
    Connect(ID_BUTTON_BROWSEDOT,wxEVT_COMMAND_BUTTON_CLICKED,(wxObjectEventFunction)&ConfigPanel::OnButtonBrowseDotClick);
    Connect(ID_BUTTON_BROWSECHMVIEWER,wxEVT_COMMAND_BUTTON_CLICKED,(wxObjectEventFunction)&ConfigPanel::OnButtonBrowseCHMViewerClick);
    Connect(ID_CHECKBOX_OVERWRITEDOXYFILE,wxEVT_COMMAND_CHECKBOX_CLICKED,(wxObjectEventFunction)&ConfigPanel::OnCheckBoxOverwriteDoxyfileClick);
    Connect(ID_CHECKBOX_USEATINTAGS,wxEVT_COMMAND_CHECKBOX_CLICKED,(wxObjectEventFunction)&ConfigPanel::OnCheckBoxUseAtInTagsClick);
    //*)

}

/*实现功能: Destructor
 */
ConfigPanel::~ConfigPanel()
{
    //(*Destroy(ConfigPanel)
    //*)
}

/*实现功能: Initialise dependent control states.
 *
 * \return void
 *
 * This function must be called after the setters have been called so that initial
 * states are set first.
 */
void ConfigPanel::Init()
{
    //    If the project uses autoversioning, enable the "Use AutoVersioning" checkbox.
    if(m_bAutoVersioning){
        CheckBoxUseAutoVersion->Enable(true);
    }
    if(!CheckBoxOverwriteDoxyfile->IsChecked()){
        CheckBoxPromptBeforeOverwriting->Enable(false);
    }
    WriteBlockComment(TextCtrlBlockComment, RadioBoxBlockComments->GetSelection(), CheckBoxUseAtInTags->GetValue());
    WriteLineComment(TextCtrlLineComment, RadioBoxLineComments->GetSelection());
    InitSTC(TextCtrlBlockComment);
    InitSTC(TextCtrlLineComment);
    if(m_bAutoVersioning){
        CheckBoxUseAutoVersion->SetValue(m_bUseAutoVersion);
        // If "Use AutoVersion" is enabled, disable the version text box so that manual entry is
        // disallowed but the detected version is still visible.
        if(m_bUseAutoVersion){
            TextCtrlProjectNumber->Enable(false);
        }
    }

    if(CheckBoxGenerateHTML->IsChecked()){
        CheckBoxGenerateHTMLHelp->Enable(true);
        CheckBoxGenerateCHI->Enable(true);
        CheckBoxBinaryTOC->Enable(true);
    }
    else{
        CheckBoxGenerateHTMLHelp->Enable(false);
        CheckBoxGenerateCHI->Enable(false);
        CheckBoxBinaryTOC->Enable(false);
    }

    if(CheckBoxWarnings->IsChecked()){
        CheckBoxWarnIfDocError->Enable(true);
        CheckBoxWarnIfUndocumented->Enable(true);
        CheckBoxWarnNoParamdoc->Enable(true);
    }
    else{
        CheckBoxWarnIfDocError->Enable(false);
        CheckBoxWarnIfUndocumented->Enable(false);
        CheckBoxWarnNoParamdoc->Enable(false);
    }
}

/*实现功能: Initialise a wxStyledTextControl.
 *
 * \param    stc    cbStyledTextCtrl*    The text editor control.
 *
 * This function initialises the styled text controls used for the comment samples.
 * It sets the lexer, margin, font and other parameters and colourises the text.
 */
void ConfigPanel::InitSTC(cbStyledTextCtrl *stc)
{
    stc->SetLexer(wxSCI_LEX_CPP);
    stc->SetMarginType(0, wxSCI_MARGIN_NUMBER);
    stc->SetMarginWidth(0, 32);
    stc->SetTabWidth(4);
    // Try to stop flickering.
    stc->SetBufferedDraw(true);
    stc->SetReadOnly(true);
    stc->SetUseHorizontalScrollBar(false);

    ConfigManager* cfg = Manager::Get()->GetConfigManager(wxT("editor"));
    wxString sFont = cfg->Read(wxT("/font"), wxEmptyString);
    wxFont fnt(10, wxFONTFAMILY_MODERN, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_NORMAL);
    if (!sFont.IsEmpty())
    {
        wxNativeFontInfo nfi;
        nfi.FromString(sFont);
        fnt.SetNativeFontInfo(nfi);
    }

    if (stc)
    {
        // Colourise.
        EditorColourSet* colour_set = Manager::Get()->GetEditorManager()->GetColourSet();
        if (!colour_set)
            return;
        stc->StyleSetFont(wxSCI_STYLE_DEFAULT, fnt);
        colour_set->Apply(colour_set->GetHighlightLanguage(wxT("C/C++")), stc);
    }
}

/*实现功能: Write the block comment sample, based on the radio box selection.
 *
 * \param    stc                        cbStyledTextCtrl*    The text editor control.
 * \param    iBlockComment     int                        The comment style.
 * \param     bUseAtInTags         bool                        Whether or not to use "@" in tags rather than "\".
 *
 */
void ConfigPanel::WriteBlockComment(cbStyledTextCtrl *stc, int iBlockComment, bool bUseAtInTags)
{
    wxString sTagChar = bUseAtInTags ? wxT("@") : wxT("\\");
    wxString sSpace(wxT(" "));
    // Comment strings.
    // 注释设置
    wxString sBrief(sSpace + wxT("这是一个简短的程序块功能描述."));
    wxString sParam1(wxString(wxT("\tp1 ")) + wxT("第一个参数."));
    wxString sParam2(wxString(wxT("\tp2 "))  + wxT("第二个参数."));
    wxString sReturn(wxString(wxT("\t")) + wxT("返回值."));
    wxString sDetailed(sSpace + wxT("这是详细的描述."));
    wxString sFunction(wxT("wxString Function(wxInt32 p1, wxString p2)"));
    wxString sBrace(wxT("{"));
    wxString sTagBrief(sSpace + sTagChar + wxT("实现功能"));
    wxString sTagParam(sSpace + sTagChar + wxT("参数"));
    wxString sTagReturn(sSpace + sTagChar + wxT("返回值"));
    wxString sStartComment;
    wxString sMidComment;
    wxString sEndComment;

    // Allow for the greater space used by C++ slashes. I like things neat. :-)
    // 允许C++斜杠使用较大的空间.我喜欢整洁的东西.
    if(iBlockComment == 1 || iBlockComment == 2 || iBlockComment == 5){
        sReturn = wxString(wxT("\t\t")) + wxT("返回值.");
    }
    switch(iBlockComment){
        case 0:
            //C/Javadoc.
            sStartComment = wxT("/**");
            sMidComment = wxT(" *");
            sEndComment = wxT(" */");
            break;
        case 1:
            // C++ exclamation.
            // C/C++感叹号注释风格
            sStartComment = wxT("//!");
            sMidComment = wxT("//!");
            sEndComment = wxT("//!");
            break;
        case 2:
            // C++ slash.
            // C++(多)斜杆注释风格
            sStartComment = wxT("///");
            sMidComment = wxT("///");
            sEndComment = wxT("///");
            break;
        case 3:
            // Qt.
            // Qt注释风格
            sStartComment = wxT("/*!");
            sMidComment = wxT(" *");
            sEndComment = wxT(" */");
            break;
        case 4:
            // Visible C.
            // 可视C注释风格
            sStartComment = wxT("/********************************************//**");
            sMidComment = wxT(" *");
            sEndComment = wxT(" ***********************************************/");
            break;
        case 5:
            // Visible C++.
            // 可视C++注释风格
            sStartComment = wxT("/////////////////////////////////////////////////");
            sMidComment = wxT("///");
            sEndComment = wxT("/////////////////////////////////////////////////");
            break;
        default:
            break;
    }
    if(iBlockComment == 4 || iBlockComment == 5){
        stc->AddText(sStartComment);
        stc->NewLine();
        stc->AddText(sMidComment + sTagBrief + sBrief);
    }
    else{
        stc->AddText(sStartComment + sTagBrief + sBrief);
    }
    // Use NewLine() to get the correct line ending chars.
    // 使用NewLine()获得正确的行尾字符.
    stc->NewLine();
    stc->AddText(sMidComment);
    stc->NewLine();
    stc->AddText(sMidComment +sTagParam + sParam1);
    stc->NewLine();
    stc->AddText(sMidComment + sTagParam + sParam2);
    stc->NewLine();
    stc->AddText(sMidComment + sTagReturn + sReturn);
    stc->NewLine();
    stc->AddText(sMidComment);
    stc->NewLine();
    stc->AddText(sMidComment + sDetailed);
    stc->NewLine();
    stc->AddText(sEndComment);
    stc->NewLine();
    stc->AddText(sFunction);
    stc->NewLine();
    stc->AddText(sBrace);

    stc->ScrollToLine(0);
}

/*
 * 实现功能: Write the line comment sample, based on the radio box selection.
 * \param    stc                        cbStyledTextCtrl*    The text editor control.
 * \param    iLineComment         int                        The comment style.
 *
 * 实现功能: 根据所选的单选框编写行注释示例.
 * 参数: stc cbStyledTextCtrl* 一个带样式的文本编辑器控件.
 * 参数: iLineComment int 注释样式.
 */
void ConfigPanel::WriteLineComment(cbStyledTextCtrl *stc, int iLineComment)
{
    // Comment strings.注释字符床
    wxString sGlobal(wxT("wxInt32\tiGlob;\t"));
    wxString sComment(wxT("代码行内注释."));
    wxString sEnum(wxT("enum Enum{"));
    wxString sVal1(wxT("\tval1 //----(枚举变量1)\t\t\t\t\t"));
    wxString sVal2(wxT("\tval2 //----(枚举变量2)\t\t\t\t\t"));
    wxString sFunction(wxT("wxString Function(wxInt32 p1, wxString p2)"));
    wxString sFuncVal(wxT("\twxInt32\tiVal;\t"));
    wxString sOpenBrace(wxT("{"));
    wxString sCloseBrace(wxT("}"));
    wxString sStartComment;
    wxString sEndComment;

    switch(iLineComment){
        case 0:            //C/Javadoc.
            sStartComment = wxT("/**< ");
            sEndComment = wxT(" */");
            break;
        case 1:            // C++ exclamation.
            sStartComment = wxT("//!< ");
            break;
        case 2:            // C++ slash.
            sStartComment = wxT("///< ");
            break;
        case 3:            // Qt.
            sStartComment = wxT("/*!< ");
            sEndComment = wxT(" */");
            break;
        default:
            break;
    }
    stc->AddText(sGlobal + sStartComment + sComment + sEndComment);
    // Use NewLine() to get the correct line ending chars.
    // 使用NewLine()获得正确的行尾字符.
    stc->NewLine();
    stc->NewLine();
    stc->AddText(sEnum);
    stc->NewLine();
    stc->AddText(sVal1 + sStartComment + sComment + sEndComment);
    stc->NewLine();
    stc->AddText(sVal2 + sStartComment + sComment + sEndComment);
    stc->NewLine();
    stc->AddText(sCloseBrace);
    stc->NewLine();
    stc->NewLine();
    stc->AddText(sFunction);
    stc->NewLine();
    stc->AddText(sOpenBrace);
    stc->NewLine();
    stc->AddText(sFuncVal + sStartComment + sComment + sEndComment);
}

/*
 * 实现功能: Apply configuration changes.
 * Virtual routine required by cbConfigurationPanel
 *
 * 实现功能: 应用配置更改.
 * cbConfigurationPanel所需的虚拟例程
 */
void ConfigPanel::OnApply()
{
    m_pOwnerClass->OnDialogueDone(this);
 }

/*
 * 实现功能: Get the base name for the images to be displayed in the settings image list.
 * \return wxString    The bitmap base name.
 * Virtual routine required by cbConfigurationPanel
 *
 * 实现功能: 获取要在"设置图像"列表中显示的图像的基名称.
 * 返回值 wxString    位图的基本名称.
 * cbConfigurationPanel所需的虚拟例程
 *
 */
wxString ConfigPanel::GetBitmapBaseName() const
{
    wxString pngName = wxT("generic-plugin");
    #ifdef __WXGTK__
     if ( ::wxFileExists(ConfigManager::GetDataFolder() + wxT("/images/settings/DoxyBlocks.png")) )
    #else
     if ( ::wxFileExists(ConfigManager::GetDataFolder() + wxT("\\images\\settings\\DoxyBlocks.png")) )
    #endif
        pngName = wxT("DoxyBlocks");
    return pngName;
}

/*
 * 实现功能: The doxygen path browse button was clicked.
 * \param     event    A wxCommandEvent reference.
 *
 * 实现功能: 已单击doxygen路径"浏览"按钮.
 * 参数:    event    wxCommandEvent事件引用.
 *
 */
void ConfigPanel::OnButtonBrowseDoxygenClick(wxCommandEvent& WXUNUSED(event))
{
    wxString sPathDoxygen = GetApplicationPath();
    if(!sPathDoxygen.empty()){
        TextCtrlPathDoxygen->SetValue(sPathDoxygen);
    }
}

/*
 * 实现功能: The doxywizard path browse button was clicked.
 * param     event    wxCommandEvent&    A wxCommandEvent object.
 *
 * 实现功能: The doxywizard path browse button was clicked.
 * 参数:    event    wxCommandEvent&   wxCommandEvent对象.
 *
 */
void ConfigPanel::OnButtonBrowseDoxywizardClick(wxCommandEvent& WXUNUSED(event))
{
    wxString sPathDoxywizard = GetApplicationPath();
    if(!sPathDoxywizard.empty()){
        TextCtrlPathDoxywizard->SetValue(sPathDoxywizard);
    }
}

/*
 * 实现功能: The HHC path browse button was clicked.
 * param     event    wxCommandEvent&    A wxCommandEvent object.
 *
 * 实现功能: 已单击HHC路径"浏览"按钮.
 * 参数:     event    wxCommandEvent&    wxCommandEvent对象.
 *
 */
void ConfigPanel::OnButtonBrowseHHCClick(wxCommandEvent& WXUNUSED(event))
{
    wxString sPathHHC = GetApplicationPath();
    if(!sPathHHC.empty()){
        TextCtrlPathHHC->SetValue(sPathHHC);
    }
}

/*
 * 实现功能: The Dot path browse button was clicked.
 * \param     event    wxCommandEvent&    A wxCommandEvent object.
 *
 */
void ConfigPanel::OnButtonBrowseDotClick(wxCommandEvent& WXUNUSED(event))
{
    wxString sPathDot = GetApplicationPath();
    if(!sPathDot.empty()){
        TextCtrlPathDot->SetValue(sPathDot);
    }
}

/*
 * 实现功能: The CHM Viewer path browse button was clicked.
 * \param     event    wxCommandEvent&    A wxCommandEvent object.
 *
 */
void ConfigPanel::OnButtonBrowseCHMViewerClick(wxCommandEvent& WXUNUSED(event))
{
    wxString sPathCHMViewer = GetApplicationPath();
    if(!sPathCHMViewer.empty()){
        TextCtrlPathCHMViewer->SetValue(sPathCHMViewer);
    }
}

/*
 * 实现功能: Display a file dialogue and return the selected path.
 * \return     wxString    The application path.
 *
 * 实现功能: 显示文件对话框并返回选定的路径.
 * 返回值:     wxString    应用程序路径.
 *
 */
wxString ConfigPanel::GetApplicationPath()
{
#ifdef __WXMSW__
    // Windows executables.
    wxString sAppFiles(_("Executable Files (*.exe)|*.exe"));
#else
    // 否则所有文件.
    wxString sAppFiles(wxT("所有类型 (*.*)|*.*"));
#endif
    return wxFileSelector(wxT("应用程序文件的路径"), wxEmptyString, wxEmptyString, wxEmptyString, sAppFiles, wxFD_OPEN|wxFD_FILE_MUST_EXIST, this);
}

/*
 * 实现功能: A block comment radio button was selected.
 * \param     event    wxCommandEvent&    A wxCommandEvent object.
 *
 */
void ConfigPanel::OnRadioBoxBlockCommentsSelect(wxCommandEvent& event)
{
    // We can't clear or write while readonly is set. :-(
    // 设置只读时无法清除或写入
    TextCtrlBlockComment->SetReadOnly(false);
    TextCtrlBlockComment->ClearAll();
    bool bUseAtInTags = CheckBoxUseAtInTags->IsChecked();
    WriteBlockComment(TextCtrlBlockComment, event.GetSelection(), bUseAtInTags);
    TextCtrlBlockComment->SetReadOnly(true);
}

/*
 * 实现功能: A line comment radio button was selected.
 * \param     event    wxCommandEvent&    A wxCommandEvent object.
 *
 */
void ConfigPanel::OnRadioBoxLineCommentsSelect(wxCommandEvent& event)
{
    // We can't clear or write while readonly is set. :-(
    TextCtrlLineComment->SetReadOnly(false);
    TextCtrlLineComment->ClearAll();
    WriteLineComment(TextCtrlLineComment, event.GetSelection());
    TextCtrlLineComment->SetReadOnly(true);
}

/*
 * 实现功能: The Generate HTML check box was clicked. Enable or disable dependent checkboxes.
 * \param     event    wxCommandEvent&    A wxCommandEvent object.
 *
 */
void ConfigPanel::OnCheckBoxGenerateHTMLClick(wxCommandEvent& event)
{
    if(event.IsChecked()){
        CheckBoxGenerateHTMLHelp->Enable(true);
        CheckBoxGenerateCHI->Enable(true);
        CheckBoxBinaryTOC->Enable(true);
    }
    else{
        CheckBoxGenerateHTMLHelp->Enable(false);
        CheckBoxGenerateCHI->Enable(false);
        CheckBoxBinaryTOC->Enable(false);
    }
}

/*
 * 实现功能: The Overwrite Doxyfile check box was clicked. Enable or disable dependent checkboxes.
 * \param     event    wxCommandEvent&    A wxCommandEvent object.
 *
 * 实现功能: 已单击"覆盖Doxy文件"复选框.启用或禁用依赖复选框.
 * 参数:    event    wxCommandEvent&   wxCommandEvent对象.
 *
 */
void ConfigPanel::OnCheckBoxOverwriteDoxyfileClick(wxCommandEvent& event)
{
    if(event.IsChecked()){
        CheckBoxPromptBeforeOverwriting->Enable(true);
    }
    else{
        CheckBoxPromptBeforeOverwriting->Enable(false);
    }
}

/*
 * 实现功能: The Warnings check box was clicked. Enable or disable dependent checkboxes.
 * \param     event    wxCommandEvent&    A wxCommandEvent object.
 *
 * 实现功能: 已单击"警告"复选框.启用或禁用依赖复选框.
 * 参数:     event    wxCommandEvent&   wxCommandEvent对象.
 *
 */
void ConfigPanel::OnCheckBoxWarningsClick(wxCommandEvent& event)
{
    if(event.IsChecked()){
        CheckBoxWarnIfDocError->Enable(true);
        CheckBoxWarnIfUndocumented->Enable(true);
        CheckBoxWarnNoParamdoc->Enable(true);
    }
    else{
        CheckBoxWarnIfDocError->Enable(false);
        CheckBoxWarnIfUndocumented->Enable(false);
        CheckBoxWarnNoParamdoc->Enable(false);
    }
}

/*
 * 实现功能: The "Use AutoVersion" checkbox was clicked. Update the "Project Number" text control.
 * \param     event    wxCommandEvent&    A wxCommandEvent object.
 * \return     void
 *
 * This function disables the "Project Number" text control if "Use AutoVersion" is selected.
 * This prevents manual entry but allows the detected version number to still be visible.
 *
 * 实现功能: 已单击:使用自动版本"复选框.更新"项目编号"文本控件.
 * 参数     event    wxCommandEvent&    wxCommandEvent对象.
 * 返回值     void
 *
 * 如果选择"使用自动版本",此函数将禁用"项目编号"文本控件.
 * 这可以防止手动输入,但允许检测到的版本号仍然可见.
 *
 */
void ConfigPanel::OnCheckBoxUseAutoversionClick(wxCommandEvent& event)
{
    if(event.IsChecked()){
        TextCtrlProjectNumber->Enable(false);
    }
    else{
        TextCtrlProjectNumber->Enable(true);
    }
}

/*
 * 实现功能: The "Use @ In Tags" checkbox was clicked. Refresh the block comment sample with the new tag.
 * \param     event    wxCommandEvent&    A wxCommandEvent object.
 * \return     void
 *
 * 实现功能: 单击了"在标记中使用@"复选框.用新标记刷新块注释示例.
 * 参数     event    wxCommandEvent&    wxCommandEvent对象.
 * 返回值     void
 *
 */
void ConfigPanel::OnCheckBoxUseAtInTagsClick(wxCommandEvent& WXUNUSED(event))
{
    bool bUseAltInTags = CheckBoxUseAtInTags->IsChecked();
    int iBlockComment = RadioBoxBlockComments->GetSelection();
    // We can't clear or write while readonly is set. :-(
    TextCtrlBlockComment->SetReadOnly(false);
    TextCtrlBlockComment->ClearAll();
    WriteBlockComment(TextCtrlBlockComment, iBlockComment, bUseAltInTags);
    TextCtrlBlockComment->SetReadOnly(true);
}

